<!DOCTYPE html>
<html>
	<head>
		<meta charset="UTF-8">
		<title></title>
		<!--引用外部脚本文件-->
		<script type="text/javascript" src="js/myScript.js" ></script>
		<script>
			fun1();
		</script>
	</head>
	<body>
		<!--标签属性中的脚本-->
		<a href="javascript:alert('ok')">行内的js</a>
	</body>
</html>
